#include<iostream>
#include<memory>
#include"SelectServer.hpp"

using namespace std;
// ./select_server 8080
int main(int argc,char* argv[])
{
    if(argc!=2)
    {
        cout<<"Usage:./select_server [port]"<<endl;
        return 1;
    }
    uint16_t port=stoi(argv[1]);
    unique_ptr<SelectServer>svr =make_unique<SelectServer>(port);
    svr->InitServer();
    svr->Loop();
    return 0;
}